Conventionally, HDDs (hard disk drives) are mounted in image forming apparatuses, and in addition to storing programs, HDDs are provided with a storage function for performing image data saving, editing, or the like. In current 3.5 inch HDDs, there are those in circulation that have a storage capacity of 1 terabyte for one disk, and with a PMR (Perpendicular Magnetic Recording) method which is currently a mainstream recording method, a limit on recording density will be reached soon.
Since, due to a rapid increase in the amount of information handled by electronic devices in recent years, demand for mounting a large capacity storage device is rising, an SMR (Shingled Magnetic Recording) format has been proposed as a recording method for exceeding the limit of the PMR method. The SMR method is a method in which signals are recorded in new tracks that overlap part of the previously recorded magnetic tracks as in the case of laying roof shingles. In the SMR method, a track group comprising a plurality of adjacent recording tracks (hereinafter referred to as a zone) is defined as a recording unit. Accordingly, in recording, a random write of data as in the PMR method cannot be performed, and only a sequential write of data can be performed. In other words, upon deletion or updating of a portion of data recorded in a zone, new data is added to a vacant sector, and for an area, in which the deletion or update target data is stored, the area's address information is simply registered in management information as an unused area and the data stored in the area is left as it is. Accordingly, when zones including these kinds of areas increase, unused zones and zones to which addition of data is possible disappear. For this reason, because addition of data becomes impossible in spite of the fact that there are vacant areas (unused areas) on the magnetic disk, periodic cleaning processing is necessary.
Also, in the SMR method, a relationship between logical addresses and physical addresses, unlike in conventional methods, is not a one-to-one relationship, and link destinations change automatically in accordance with disk usage conditions, and address link conditions are managed by management information within the HDD.
Meanwhile, demand for security guarantees and for protection of privacy is very high, and there are cases in which there is a need for spool data and saved data recorded in a storage unit in an image forming apparatus to be completely deletable. To eliminate a residual magnetism when data that is saved in an HDD is deleted, a complete delete of data is performed by overwriting an area to which deletion target data is recorded a plurality of times with dummy data (for example, refer to Japanese Patent Laid-Open No. 2004-234473, and Japanese Patent Laid-Open No. 2009-093242).
However, because items of data are written to be overlapped in an HDD of the SMR method, it is impossible to overwrite only the data area desired to be deleted, and the relationship between physical addresses and logical addresses is not fixed. Accordingly, there is a problem in that processing, which has been performed in an HDD of conventional method, for deleting completely a deletion target data by overwriting the area of the deletion target data with dummy data a plurality of times cannot be performed.
Also, there is the possibility that if the above described cleaning processing is performed during processing such as continuous reading/writing, performance will deteriorate because the reading/writing processing will be made to wait during the cleaning processing. Also, similarly to a case in which a sufficient cache area cannot be allocated, the time required for the cleaning processing becomes longer, and performance deteriorates.